import 'package:flutter/material.dart';
import 'package:poet/components/poet_item.dart';
import 'package:poet/pages/search_page/components/item_group.dart';

class AuthorPage extends StatefulWidget {
  @override
  State<StatefulWidget> createState() {
    return _AuthorPage();
  }
}

class _AuthorPage extends State<AuthorPage> {
  final _contentTypes = ["介绍", "创作", "故事"];

  void _onTypeChange(String type) {}

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text("李白"),
      ),
      body: Column(
        children: <Widget>[
          Expanded(
            child: PoetItem(),
          ),
          ItemGroup(
            onItemChange: _onTypeChange,
            items: _contentTypes,
          ),
        ],
      ),
    );
  }
}
